- community_location_lat = @current_community.location ? @current_community.location.latitude : nil
- community_location_lon = @current_community.location ? @current_community.location.longitude : nil

- content_for :extra_javascript do
  :javascript
    initialize_labels();

    $(document).ready(function() {
      initialize_listing_map(
        #{raw listings_for_map(@listings).to_json},
        "#{community_location_lat}",
        "#{community_location_lon}",
        #{raw viewport.to_json},
        "#{I18n.locale}",
        "#{@current_community.use_community_location_as_default}");
      });

#map-canvas.map
